package spikes_activity

import (
	"github.com/flipped-aurora/gin-vue-admin/server/middleware"
	"github.com/gin-gonic/gin"
)

type SpikesActivitiesRouter struct {}

// InitSpikesActivitiesRouter 初始化 spikesActivities表 路由信息
func (s *SpikesActivitiesRouter) InitSpikesActivitiesRouter(Router *gin.RouterGroup,PublicRouter *gin.RouterGroup) {
	spikesActivitiesRouter := Router.Group("spikesActivities").Use(middleware.OperationRecord())
	spikesActivitiesRouterWithoutRecord := Router.Group("spikesActivities")
	spikesActivitiesRouterWithoutAuth := PublicRouter.Group("spikesActivities")
	{
		spikesActivitiesRouter.POST("createSpikesActivities", spikesActivitiesApi.CreateSpikesActivities)   // 新建spikesActivities表
		spikesActivitiesRouter.DELETE("deleteSpikesActivities", spikesActivitiesApi.DeleteSpikesActivities) // 删除spikesActivities表
		spikesActivitiesRouter.DELETE("deleteSpikesActivitiesByIds", spikesActivitiesApi.DeleteSpikesActivitiesByIds) // 批量删除spikesActivities表
		spikesActivitiesRouter.PUT("updateSpikesActivities", spikesActivitiesApi.UpdateSpikesActivities)    // 更新spikesActivities表
	}
	{
		spikesActivitiesRouterWithoutRecord.GET("findSpikesActivities", spikesActivitiesApi.FindSpikesActivities)        // 根据ID获取spikesActivities表
		spikesActivitiesRouterWithoutRecord.GET("getSpikesActivitiesList", spikesActivitiesApi.GetSpikesActivitiesList)  // 获取spikesActivities表列表
	}
	{
	    spikesActivitiesRouterWithoutAuth.GET("getSpikesActivitiesPublic", spikesActivitiesApi.GetSpikesActivitiesPublic)  // spikesActivities表开放接口
	}
}
